/**
 * @file rk_list_process.h
 * @author your name (you@domain.com)
 * @brief 检测目标链表处理相关事务
 * @version 0.1
 * @date 2022-12-31
 * 
 * @copyright Copyright (c) 2022
 * 
 */
#include <stddef.h>
#include "customized_struct.h"
#define DRAW_INDEX 0
#define RK_NN_INDEX 1
#define MAX_RKNN_LIST_NUM 10      //如果GetMediaBuffer线程检测到的目标已经超过了10个，就从队列中排出第一个成员

typedef struct node {
  long timeval;
  detect_result_group_t detect_result_group;
  struct node *next;
} Node;

typedef struct my_stack {
  int size;
  Node *top;
} rknn_list;

long getCurrentTimeMsec();

void create_rknn_list(rknn_list **s);

void destory_rknn_list(rknn_list **s);

void rknn_list_push(rknn_list *s, long timeval,
                    detect_result_group_t detect_result_group);

void rknn_list_pop(rknn_list *s, long *timeval,
                   detect_result_group_t *detect_result_group);

void rknn_list_drop(rknn_list *s);

int rknn_list_size(rknn_list *s);